/**
 * /*
 *
 * @format
 * @Author: Your name
 * @Date: 2020-08-20 20:35:05
 * @Last Modified by:   Your name
 * @Last Modified time: 2020-08-20 20:35:05
 */

import { IReqApi, IReq, IResList } from '@/api/core'

export const API_GET_PRODUCT_LIST: IReqApi = {
  title: '获取产品分类菜单',
  method: 'POST',
  path: 'product/getProductList',
  prefix: 'api',
  version: 'applets',
}

// req
export interface IReqGetProductList extends IReq {
  tab?: number
  sort?: number
  title?: string
  categoryId?: number
}

// res
export interface IResGetProductList extends IResList<IResGetProductListItem> {}

// resItem
export interface IResGetProductListItem {
  spuSn: string
  cover: string
  mainName: string
  minPrice: number
  maxPrice: number
  descriptions: string
  categoryId: number

  // countDown: string
  // unitOfMeasurement: string

  isTimeLimited: boolean
  isNewSale: boolean
  isHotSale: boolean
  sales: number
  // limitedPrice: number
}
